package com.cloud.demo.common.web.exception;

import com.cloud.demo.common.enums.ResultEnum;
import lombok.Data;

@Data
public class SysException extends RuntimeException{
    private int code;
    private String massage;
    private ResultEnum resultEnum;
    public SysException(ResultEnum resultEnum){
        this.code=resultEnum.getCode();
        this.massage = resultEnum.getMessage();
        this.resultEnum = resultEnum;
    }

}
